2020-2021 Sunseeker Telemetry and Lighting System
adc_ex1_avccRef.c File Reference
#include "driverlib.h"
#include "Board.h"

Go to the source code of this file.

Functions

void main (void)
 
void ADC_ISR (void)
 

Function Documentation

◆ ADC_ISR()

void ADC_ISR ( void  )

◆ main()

void main ( void  )

ADC - Sample A7 Input, AVcc Ref, LED1 and LED2 is set if A7 > 0.5AVcc

MSP430FR4133 Demo A single sample is made on A7 with reference to AVcc. Software sets ADC10SC to start sample and conversion - ADC10SC automatically cleared at EOC.ADC internal oscillator times sample (16x) and conversion. In Mainloop MSP430 waits in LPM0 to save power until ADC conversion complete, ADC10_ISR will force exit from LPM0 in Mainloop on reti. If A7 > 0.5*AVcc, LED1 and LED2 set, else reset.

MSP430FR2xx_4xx Board

/|| XIN|- | | | –|RST XOUT|- | | >—|A7 |-->LED1 | |-->LED2

This example uses the following peripherals and I/O signals. You must review these and change as needed for your own board:

  • ADC10 peripheral
  • GPIO Port peripheral
  • A7

This example uses the following interrupt handlers. To use this example in your own application you must add these interrupt handlers to your vector table.

  • ADC10_VECTOR

Definition at line 67 of file adc_ex1_avccRef.c.

References __delay_cycles(), and __no_operation().